<html>
<head><meta charset="utf-8"><title>RPIT Lifetime issues · wg-traits · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/index.html">wg-traits</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html">RPIT Lifetime issues</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="155109123"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109123" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109123">(Jan 14 2019 at 19:25)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> <span class="user-mention" data-user-id="116009">@nikomatsakis</span> and I discussed this previously (and <span class="user-mention" data-user-id="119009">@eddyb</span> chipped in a bit). I think we want to use <code>for&lt;'a&gt;</code> (or a new keyword, but preferably reuse that one) to bind such lifetimes.</p>



<a name="155109132"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109132" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109132">(Jan 14 2019 at 19:25)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span></p>



<a name="155109212"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109212" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109212">(Jan 14 2019 at 19:26)</a>:</h4>
<p>^</p>



<a name="155109274"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109274" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109274">(Jan 14 2019 at 19:27)</a>:</h4>
<p>I guess the semantics would be quite simple: capturing the variables and doing nothing.</p>



<a name="155109289"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109289" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109289">(Jan 14 2019 at 19:27)</a>:</h4>
<p>Maybe paste in the issues for context here?</p>



<a name="155109290"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109290" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109290">(Jan 14 2019 at 19:27)</a>:</h4>
<p>appropriate diagnostics might be a bit harder</p>



<a name="155109304"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109304" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109304">(Jan 14 2019 at 19:27)</a>:</h4>
<p>I want to be sure I know which issues you are talking about</p>



<a name="155109306"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109306" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109306">(Jan 14 2019 at 19:27)</a>:</h4>
<p>Here they are.</p>



<a name="155109310"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109310" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109310">(Jan 14 2019 at 19:27)</a>:</h4>
<p>1. <a href="https://github.com/rust-lang/rust/issues/34511#issuecomment-373423999" target="_blank" title="https://github.com/rust-lang/rust/issues/34511#issuecomment-373423999">https://github.com/rust-lang/rust/issues/34511#issuecomment-373423999</a> (@eddyb has some thoughts about this, but he hasn't been around for a while now, and @nikomatsakis understands it anyway)<br>
2. <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">https://github.com/rust-lang/rust/issues/42940</a><br>
3. Possibly <a href="https://github.com/rust-lang/rust/issues/55929" target="_blank" title="https://github.com/rust-lang/rust/issues/55929">https://github.com/rust-lang/rust/issues/55929</a> is related to or even the same as 1?</p>



<a name="155109411"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109411" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109411">(Jan 14 2019 at 19:28)</a>:</h4>
<p>I'm not sure what the "issue" with (1) is</p>



<a name="155109476"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109476" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109476">(Jan 14 2019 at 19:29)</a>:</h4>
<p>It was addressed in <a href="https://github.com/rust-lang/rust/pull/49041" target="_blank" title="https://github.com/rust-lang/rust/pull/49041">https://github.com/rust-lang/rust/pull/49041</a></p>



<a name="155109613"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109613" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109613">(Jan 14 2019 at 19:30)</a>:</h4>
<p>in order to capture lifetimes, you have to add a <code>Captures</code> trait in order to pick up the lifetime in the bounds</p>



<a name="155109660"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109660" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109660">(Jan 14 2019 at 19:31)</a>:</h4>
<p>Is there something else going on there that you think we should resolve?</p>



<a name="155109662"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109662" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109662">(Jan 14 2019 at 19:31)</a>:</h4>
<p>"The key thing here is that TyCtxt is invariant w/r/t 'tcx and 'gcx, so they must appear in the return type. And yet only 'cx and 'tcx appear in the impl trait bounds, so only those two lifetimes are supposed to be "captured". The old compiler was accepting this because 'gcx: 'cx, but that's not really correct if you think about the desugaring we have in mind. That desugaring would create an abstract type like this:"</p>



<a name="155109670"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109670" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109670">(Jan 14 2019 at 19:31)</a>:</h4>
<p>that's the key bit</p>



<a name="155109676"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109676" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109676">(Jan 14 2019 at 19:31)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> I started doing that, but <span class="user-mention" data-user-id="116009">@nikomatsakis</span> doesn't like it, and prefers a language-based solution.</p>



<a name="155109778"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109778" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109778">(Jan 14 2019 at 19:32)</a>:</h4>
<p>What sort of "language-based" solution?</p>



<a name="155109908"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109908" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109908">(Jan 14 2019 at 19:34)</a>:</h4>
<p>(I'm curious because some kind of language-level LUB('a, 'b, ...) would also fix my issues with <code>async fn</code>)</p>



<a name="155109924"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109924" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109924">(Jan 14 2019 at 19:34)</a>:</h4>
<p>as well as fixing (2), I believe</p>



<a name="155109930"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109930" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109930">(Jan 14 2019 at 19:34)</a>:</h4>
<p>(or at least giving a workaround)</p>



<a name="155109935"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109935" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109935">(Jan 14 2019 at 19:34)</a>:</h4>
<p>See my first comment in this thread. :-)</p>



<a name="155109946"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109946" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109946">(Jan 14 2019 at 19:34)</a>:</h4>
<p>At least, that's what we talked about before.</p>



<a name="155109956"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109956" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109956">(Jan 14 2019 at 19:34)</a>:</h4>
<p>It need not be the only possible solution though...</p>



<a name="155109962"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109962" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109962">(Jan 14 2019 at 19:35)</a>:</h4>
<p>using <code>for&lt;'a&gt;</code>?</p>



<a name="155109976"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109976" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109976">(Jan 14 2019 at 19:35)</a>:</h4>
<p>/me waits for <span class="user-mention" data-user-id="116009">@nikomatsakis</span> to chip in.</p>



<a name="155109984"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109984" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109984">(Jan 14 2019 at 19:35)</a>:</h4>
<p>yeah</p>



<a name="155109985"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155109985" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155109985">(Jan 14 2019 at 19:35)</a>:</h4>
<p>can you give an example?</p>



<a name="155110108"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110108" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110108">(Jan 14 2019 at 19:36)</a>:</h4>
<p>I think something like <code>fn foo(self) -&gt; impl for&lt;'gcx&gt; Iterator&lt;Item = &amp;'tcx Foo&gt; + 'cx {</code></p>



<a name="155110134"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110134" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110134">(Jan 14 2019 at 19:37)</a>:</h4>
<p>that seems misleading to me</p>



<a name="155110135"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110135" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110135">(Jan 14 2019 at 19:37)</a>:</h4>
<p>alternatively, we build it into the <code>impl</code> syntax, e.g. <code>impl&lt;'gcx&gt; Iterator...</code></p>



<a name="155110145"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110145" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110145">(Jan 14 2019 at 19:37)</a>:</h4>
<p>because <code>for</code> there looks like part of the bound</p>



<a name="155110154"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110154" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110154">(Jan 14 2019 at 19:37)</a>:</h4>
<p>it is part of the bound</p>



<a name="155110157"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110157" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110157">(Jan 14 2019 at 19:37)</a>:</h4>
<p>and I'd expect the bound to be quantified over <code>'gcx</code></p>



<a name="155110218"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110218" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110218">(Jan 14 2019 at 19:38)</a>:</h4>
<p>sorry, your thumb indicates that you agree, but I think the feature that is being suggested here is different?</p>



<a name="155110229"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110229" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110229">(Jan 14 2019 at 19:38)</a>:</h4>
<p>okay, move it outside the <code>impl</code> then? or take my alternative syntax?</p>



<a name="155110242"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110242" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110242">(Jan 14 2019 at 19:38)</a>:</h4>
<p>that it actually makes it part of the <code>extistentail type&lt;...&gt;</code> rather than the bound on the RHS of <code>:</code></p>



<a name="155110261"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110261" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110261">(Jan 14 2019 at 19:39)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> maybe?</p>



<a name="155110272"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110272" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110272">(Jan 14 2019 at 19:39)</a>:</h4>
<p>I'd expect <code>impl&lt;'a&gt; Foo&lt;'a&gt; + Bar&lt;'a&gt;</code> to be equivalent to <code>impl for&lt;'a&gt; (Foo&lt;'a&gt; + Bar&lt;'a&gt;)</code></p>



<a name="155110287"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110287" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110287">(Jan 14 2019 at 19:39)</a>:</h4>
<p>(which you cannot express)</p>



<a name="155110295"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110295" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110295">(Jan 14 2019 at 19:39)</a>:</h4>
<p>yes...</p>



<a name="155110453"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110453" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110453">(Jan 14 2019 at 19:41)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> thoughts on syntax? options:<br>
1. <code>impl for&lt;'a&gt; Foo&lt;'a&gt;</code><br>
2. <code>for&lt;'a&gt; impl Foo&lt;'a&gt;</code><br>
3. <code>impl&lt;'a&gt; Foo&lt;'a&gt;</code><br>
4. other?</p>



<a name="155110541"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110541" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110541">(Jan 14 2019 at 19:42)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> should I put you down for these things in the meeting notes; is that okay? (I think you know what needs to be tackle, syntax pending)</p>



<a name="155110556"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110556" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110556">(Jan 14 2019 at 19:42)</a>:</h4>
<p>and 2. doesn't require any syntactical enhancements</p>



<a name="155110557"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155110557" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155110557">(Jan 14 2019 at 19:42)</a>:</h4>
<p>that is, issue 2. <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">https://github.com/rust-lang/rust/issues/42940</a></p>



<a name="155111733"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155111733" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155111733">(Jan 14 2019 at 19:58)</a>:</h4>
<p>So...?</p>



<a name="155112038"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112038" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112038">(Jan 14 2019 at 20:02)</a>:</h4>
<p>i'm not sure I agree that something needs to happen here</p>



<a name="155112047"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112047" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112047">(Jan 14 2019 at 20:02)</a>:</h4>
<p>and certainly not without an RFC</p>



<a name="155112077"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112077" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112077">(Jan 14 2019 at 20:02)</a>:</h4>
<p>although we could possibly justify it as "experimentation"</p>



<a name="155112105"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112105" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112105">(Jan 14 2019 at 20:03)</a>:</h4>
<p>but the motivation (not using <code>Captures&lt;...&gt;</code>) seems unclear to me</p>



<a name="155112140"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112140" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112140">(Jan 14 2019 at 20:03)</a>:</h4>
<p>Also there's an interesting parallel here between <code>Captures</code> and <code>PhantomData</code></p>



<a name="155112149"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112149" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112149">(Jan 14 2019 at 20:03)</a>:</h4>
<p>I wonder if there's room for <code>PhantomTrait</code> or something</p>



<a name="155112226"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112226" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112226">(Jan 14 2019 at 20:04)</a>:</h4>
<p>can someone TL;DR the lifetime issues under discussion here?</p>



<a name="155112244"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112244" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112244">(Jan 14 2019 at 20:04)</a>:</h4>
<p><a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">https://github.com/rust-lang/rust/issues/42940</a> is the more interesting one to me</p>



<a name="155112253"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112253" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112253">(Jan 14 2019 at 20:04)</a>:</h4>
<p>I think that's the only one that just needs "fixing"</p>



<a name="155112301"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112301" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112301">(Jan 14 2019 at 20:05)</a>:</h4>
<p><code>for&lt;'a&gt; impl Foo&lt;'a&gt;</code> would be a higher ranked type; <code>impl&lt;'a&gt; Foo&lt;'a&gt;</code> would just be sugar for <code>impl for&lt;'a&gt; Foo&lt;'a&gt;</code></p>



<a name="155112302"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112302" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112302">(Jan 14 2019 at 20:05)</a>:</h4>
<p>It's just a bug</p>



<a name="155112324"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112324" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112324">(Jan 14 2019 at 20:05)</a>:</h4>
<p><span class="user-mention" data-user-id="126931">@centril</span> I think you're getting mixed up--none of this has to do with higher-rankedness</p>



<a name="155112372"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112372" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112372">(Jan 14 2019 at 20:06)</a>:</h4>
<p>that's why I don't want to use this syntax</p>



<a name="155112396"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112396" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112396">(Jan 14 2019 at 20:06)</a>:</h4>
<p>IIUC <span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> is trying to get another way to spell <code>Captures&lt;...&gt;</code></p>



<a name="155112416"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112416" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112416">(Jan 14 2019 at 20:06)</a>:</h4>
<p>which is more about variance than about higher-rankedness</p>



<a name="155112419"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112419" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112419">(Jan 14 2019 at 20:06)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span>  I'm not mixing up anything, I'm giving expected semantics to the syntaxes <span class="user-mention" data-user-id="124069">@Alexander Regueiro</span>  referenced</p>



<a name="155112444"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112444" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112444">(Jan 14 2019 at 20:07)</a>:</h4>
<p>(i.e. 1-3)</p>



<a name="155112456"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112456" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112456">(Jan 14 2019 at 20:07)</a>:</h4>
<p>I'm saying those aren't the semantics he's looking for</p>



<a name="155112460"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112460" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112460">(Jan 14 2019 at 20:07)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> sure, that's my point :P</p>



<a name="155112461"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112461" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112461">(Jan 14 2019 at 20:07)</a>:</h4>
<p>unless I'm confused (which is possible)</p>



<a name="155112478"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112478" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112478">(Jan 14 2019 at 20:07)</a>:</h4>
<p>Okay, so we're on the same page that we shouldn't reuse <code>for</code> or <code>impl</code> to add captured lifetimes to <code>impl Trait</code></p>



<a name="155112532"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112532" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112532">(Jan 14 2019 at 20:08)</a>:</h4>
<p>yep</p>



<a name="155112539"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112539" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112539">(Jan 14 2019 at 20:08)</a>:</h4>
<p>when was <code>Captures&lt;...&gt;</code> needed again?</p>



<a name="155112542"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112542" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112542">(Jan 14 2019 at 20:08)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> does that make sense to you? or did I get mixed up?</p>



<a name="155112579"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112579" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112579">(Jan 14 2019 at 20:09)</a>:</h4>
<p><span class="user-mention" data-user-id="126931">@centril</span> when you have a return type that is quantified over a lifetime but you don't want to require that the type outlive that lifetime</p>



<a name="155112588"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112588" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112588">(Jan 14 2019 at 20:09)</a>:</h4>
<p>it <em>can't live longer than</em> that lifetime</p>



<a name="155112590"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112590" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112590">(Jan 14 2019 at 20:09)</a>:</h4>
<p>but not <em>as long as</em></p>



<a name="155112677"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112677" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112677">(Jan 14 2019 at 20:10)</a>:</h4>
<p>e.g. <code>fn foo&lt;'a, 'b: 'a&gt;(x: &amp;'a str, y: &amp;'b str) -&gt; impl Debug + Captures&lt;'b&gt; + 'a { (x, y) }</code></p>



<a name="155112683"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112683" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112683">(Jan 14 2019 at 20:10)</a>:</h4>
<p>it doesn't live as long as <code>'b</code></p>



<a name="155112689"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155112689" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155112689">(Jan 14 2019 at 20:10)</a>:</h4>
<p>but it captures <code>'b</code></p>



<a name="155113963"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155113963" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155113963">(Jan 14 2019 at 20:28)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> hmm, is this <code>Captures&lt;'a&gt;</code> a common need?</p>



<a name="155113987"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155113987" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155113987">(Jan 14 2019 at 20:29)</a>:</h4>
<p>not <em>super</em> common, but it happens</p>



<a name="155114003"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155114003" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155114003">(Jan 14 2019 at 20:29)</a>:</h4>
<p>it's in rustc in several places</p>



<a name="155114236"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155114236" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155114236">(Jan 14 2019 at 20:31)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span>  hmm remind me again... what is the variance of <code>Captures&lt;'b&gt;</code> ?</p>



<a name="155118308"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155118308" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155118308">(Jan 14 2019 at 21:03)</a>:</h4>
<p><span class="user-mention" data-user-id="126931">@centril</span> I already linked to them above.</p>



<a name="155118489"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155118489" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155118489">(Jan 14 2019 at 21:04)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> I wasn't against using Captures, but it seems Niko wanted to avoid it.</p>



<a name="155118499"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155118499" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155118499">(Jan 14 2019 at 21:04)</a>:</h4>
<p>So let's get his reasoning</p>



<a name="155120197"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155120197" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155120197">(Jan 14 2019 at 21:21)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> are you good to work on issue 2 until we decide that?</p>



<a name="155120351"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155120351" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155120351">(Jan 14 2019 at 21:23)</a>:</h4>
<p>also, <a href="https://github.com/rust-lang/rust/pull/56047" target="_blank" title="https://github.com/rust-lang/rust/pull/56047">https://github.com/rust-lang/rust/pull/56047</a></p>



<a name="155132376"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155132376" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155132376">(Jan 15 2019 at 00:15)</a>:</h4>
<p><span class="user-mention" data-user-id="126931">@centril</span> <code>Captures&lt;'a&gt;</code> would surely be covariant, since it's an empty trait</p>



<a name="155227256"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155227256" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155227256">(Jan 16 2019 at 04:22)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> Could we kindly get your reasoning on 1 and why you want a solution built into the language rather than a <code>Captures</code> trait or such? I know you expressed this on my closed PR, but I think elaboration would be nice, especially for <span class="user-mention" data-user-id="127859">@Taylor Cramer</span>.</p>



<a name="155337791"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337791" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337791">(Jan 17 2019 at 14:16)</a>:</h4>
<p>sorry y'all I was late on this thread, catching up now</p>



<a name="155337879"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337879" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337879">(Jan 17 2019 at 14:17)</a>:</h4>
<p>to go back, the problem is when you have some function like <code>fn foo(..) -&gt; impl Iterator&lt;Item = &amp;'a Blah&gt;</code> but it references some lifetime like <code>'tcx</code></p>



<a name="155337891"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337891" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337891">(Jan 17 2019 at 14:17)</a>:</h4>
<p>my <em>preference</em> here would be to just accept the code as is</p>



<a name="155337897"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337897" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337897">(Jan 17 2019 at 14:17)</a>:</h4>
<p>but I want to figure out how we <em>justify</em> that :)</p>



<a name="155337918"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337918" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337918">(Jan 17 2019 at 14:18)</a>:</h4>
<p>as I wrote.. somewhere... you <em>can</em> hide lifetimes using a <code>dyn</code> type</p>



<a name="155337968"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337968" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337968">(Jan 17 2019 at 14:18)</a>:</h4>
<p>(you do need some common "denominator", though)</p>



<a name="155337970"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155337970" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155337970">(Jan 17 2019 at 14:18)</a>:</h4>
<p>i.e., a bound</p>



<a name="155338067"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155338067" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155338067">(Jan 17 2019 at 14:19)</a>:</h4>
<p>but I am now looking at <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">#42940</a> and trying to catch up with what <span class="user-mention" data-user-id="127859">@Taylor Cramer</span> was saying</p>



<a name="155338079"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155338079" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155338079">(Jan 17 2019 at 14:20)</a>:</h4>
<p>it seems like we should split the discussion a bit further</p>



<a name="155340538"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155340538" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155340538">(Jan 17 2019 at 14:51)</a>:</h4>
<p>OK, re: <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">#42940</a>, I posted a <a href="https://github.com/rust-lang/rust/issues/42940#issuecomment-455198309" target="_blank" title="https://github.com/rust-lang/rust/issues/42940#issuecomment-455198309">comment with my thoughts</a>. The TL;DR is "seems like a bug" and the fix, while non-trivial, is straight-forward-ish I think. <span class="user-mention" data-user-id="127859">@Taylor Cramer</span> maybe you want to work on it?</p>



<a name="155347385"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347385" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347385">(Jan 17 2019 at 16:11)</a>:</h4>
<p>Yeah, I can work on it, thanks for your comments. And wrt <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">#42940</a> I agree that it should "just work" but I don't know how to make that clear in the existential type desugaring. It reminds me a bit of the closure type replacement issue where you could imagine that we just replaced all lifetimes with the explicitly-mentioned bound and that the change due to invalid variance was just "unobservable", but that seems like quite a hack and not really a good justification in any formal-ish sense</p>



<a name="155347419"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347419" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347419">(Jan 17 2019 at 16:11)</a>:</h4>
<p>right, I've been hoping to put off that question</p>



<a name="155347424"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347424" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347424">(Jan 17 2019 at 16:11)</a>:</h4>
<p>which reminds me that I thought of a better variant of the captures trait...</p>



<a name="155347438"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347438" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347438">(Jan 17 2019 at 16:12)</a>:</h4>
<p>right now I think it is <code>Captures&lt;'a&gt;</code>, but that leads to trouble if you have more than one lifetime</p>



<a name="155347485"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347485" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347485">(Jan 17 2019 at 16:12)</a>:</h4>
<p>I <em>think</em> if we did <code>Captures&lt;T&gt;</code> instead, it would be better</p>



<a name="155347498"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347498" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347498">(Jan 17 2019 at 16:12)</a>:</h4>
<p>and then you could do e.g. <code>impl Foo + Captures&lt;(&amp;'a (), &amp;'b ())&gt;</code></p>



<a name="155347500"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347500" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347500">(Jan 17 2019 at 16:12)</a>:</h4>
<p>still a horrible hack</p>



<a name="155347513"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155347513" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155347513">(Jan 17 2019 at 16:12)</a>:</h4>
<p>but could be useful in rustc anyway</p>



<a name="155351775"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155351775" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155351775">(Jan 17 2019 at 17:10)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> So the idea is to fix both of these problems by making the code “just work”?</p>



<a name="155354047"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/155354047" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#155354047">(Jan 17 2019 at 17:44)</a>:</h4>
<p>Yeah, <a href="https://github.com/rust-lang/rust/issues/42940" target="_blank" title="https://github.com/rust-lang/rust/issues/42940">#42940</a> was always just a bug (albeit a subtle one), and the other thing I think niko and I agree that we should just allow the code without having to explicitly mention the lifetimes. Still not sure exactly what it should desugar to or how we should explain the fact that it works, though</p>



<a name="156400592"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156400592" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156400592">(Jan 18 2019 at 21:20)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> Yeah, I've been thinking about that too, and it's a tricky one... maybe it can be justified in an analogous way to <code>dyn Trait</code> though? Anyway, do please let me know if you and Niko decide on anything, just out of curiosity.</p>



<a name="156401706"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156401706" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156401706">(Jan 18 2019 at 21:37)</a>:</h4>
<p>I feel like the answer is that we'd have some kind of <code>exists&lt;'a&gt; Type</code> notion</p>



<a name="156401756"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156401756" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156401756">(Jan 18 2019 at 21:38)</a>:</h4>
<p>and just try to convince ourselves that it will work out ;)</p>



<a name="156401765"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156401765" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156401765">(Jan 18 2019 at 21:38)</a>:</h4>
<p>it feels like it has to be ok</p>



<a name="156401791"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156401791" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156401791">(Jan 18 2019 at 21:39)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> why would you have that for <code>impl Trait</code> but not for <code>dyn Trait</code>?</p>



<a name="156402011"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402011" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402011">(Jan 18 2019 at 21:42)</a>:</h4>
<p>dyn Trait <em>does</em> have that, in some sense. That is, <code>dyn Trait</code> is basically <code>exists T: Trait</code></p>



<a name="156402024"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402024" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402024">(Jan 18 2019 at 21:42)</a>:</h4>
<p>oh, true</p>



<a name="156402029"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402029" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402029">(Jan 18 2019 at 21:42)</a>:</h4>
<p>so what I am saying is -- conceptually -- <code>impl Trait</code> would be inferred not to <code>Foo&lt;'a, 'gcx&gt;</code> but <code>exists&lt;'gcx&gt; Foo&lt;'gcx&gt;</code></p>



<a name="156402034"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402034" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402034">(Jan 18 2019 at 21:42)</a>:</h4>
<p>actually chalk already has this kind of type, iirc</p>



<a name="156402048"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402048" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402048">(Jan 18 2019 at 21:43)</a>:</h4>
<p>well, not exactly</p>



<a name="156402053"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402053" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402053">(Jan 18 2019 at 21:43)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> oh right, so there would be no syntactical additions?</p>



<a name="156402055"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402055" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402055">(Jan 18 2019 at 21:43)</a>:</h4>
<p>but I mean that <code>forall</code> types are distinct from fns</p>



<a name="156402060"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402060" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402060">(Jan 18 2019 at 21:43)</a>:</h4>
<p>yeah I don't mean that the syntax changes</p>



<a name="156402066"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402066" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402066">(Jan 18 2019 at 21:43)</a>:</h4>
<p>sounds reasonable</p>



<a name="156402922"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156402922" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156402922">(Jan 18 2019 at 21:54)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> so correct me if I'm wrong, this still wouldn't make <code>impl Trait</code> existential in nature, but it would (just) implicitly existentially quantify invariant lifetimes?</p>



<a name="156403805"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156403805" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156403805">(Jan 18 2019 at 22:07)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> correct, this is what I have in mind</p>



<a name="156403948"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156403948" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156403948">(Jan 18 2019 at 22:09)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> okay, great. the question then is: is <span class="user-mention" data-user-id="127859">@Taylor Cramer</span> comfortable enough with Chalk to tackle this too, or should it be assigned to someone else? (Sadly I'm definitely not comfortable enough, but maybe that will change some day.)</p>



<a name="156404956"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156404956" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156404956">(Jan 18 2019 at 22:26)</a>:</h4>
<p>I definitely don't know enough to model this today</p>



<a name="156404962"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156404962" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156404962">(Jan 18 2019 at 22:26)</a>:</h4>
<p>but I'd be happy to work on learning</p>



<a name="156404974"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156404974" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156404974">(Jan 18 2019 at 22:26)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> I want to learn about Chalk too. the "technical deep dive" should be coming up soon... maybe one (or both) of us can take it on after then?</p>



<a name="156404979"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156404979" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156404979">(Jan 18 2019 at 22:26)</a>:</h4>
<p>at least, if it's next week (as I believe it is)</p>



<a name="156405253"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405253" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405253">(Jan 18 2019 at 22:31)</a>:</h4>
<p>well, next week we were going to focus on trait objects, but not "all of chalk" -- still, I'd be happy to schedule some time to talk this stuff through in an exploratory fashion (probably with both of y'all and whomever else wants to)</p>



<a name="156405256"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405256" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405256">(Jan 18 2019 at 22:31)</a>:</h4>
<p>(we could record and post too)</p>



<a name="156405378"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405378" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405378">(Jan 18 2019 at 22:33)</a>:</h4>
<p>I suspect the end result of all of this is that we'll basically just wind up removing the check we added to make the existing code an error ...</p>



<a name="156405795"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405795" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405795">(Jan 18 2019 at 22:40)</a>:</h4>
<p>Yeah, that was sort of what I was wondering ;)</p>



<a name="156405817"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405817" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405817">(Jan 18 2019 at 22:40)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> It seems like the actual task here is to just open a PR reverting that change</p>



<a name="156405831"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405831" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405831">(Jan 18 2019 at 22:41)</a>:</h4>
<p>now that we're comfortable that there exists <em>some way</em> to model this more formally</p>



<a name="156405839"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156405839" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156405839">(Jan 18 2019 at 22:41)</a>:</h4>
<p>(provided you actually do believe that now)</p>



<a name="156406011"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156406011" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156406011">(Jan 18 2019 at 22:44)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> ostensibly <code>fn foo(x: impl Trait) { ... }</code> ==&gt; <code>fn foo(x: exists&lt;T: Trait&gt; T)</code> ==&gt; <code>fn foo&lt;T: Trait&gt;(x: T)</code> whereas <code>fn foo() -&gt; impl Trait</code> ==&gt; <code>exists&lt;T: Trait&gt; fn foo()</code> but <em>not</em> <code>fn foo() -&gt; exists&lt;T: Trait&gt; T</code></p>



<a name="156407220"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156407220" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156407220">(Jan 18 2019 at 23:06)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> <span class="user-mention" data-user-id="127859">@Taylor Cramer</span> sounds fair. so we don't need to model this in Chalk then? :-)</p>



<a name="156408733"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156408733" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156408733">(Jan 18 2019 at 23:39)</a>:</h4>
<p>I mean, it should probably be done at some point</p>



<a name="156408741"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156408741" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156408741">(Jan 18 2019 at 23:39)</a>:</h4>
<p>but it's not a blocker for resolving the issue IMO</p>



<a name="156408997"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156408997" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156408997">(Jan 18 2019 at 23:44)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> from what I've just heard, I agree, yes.</p>



<a name="156409001"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409001" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409001">(Jan 18 2019 at 23:44)</a>:</h4>
<p>had any luck with the other issue yet?</p>



<a name="156409013"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409013" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409013">(Jan 18 2019 at 23:45)</a>:</h4>
<p>or still trying to find time to look at it?</p>



<a name="156409098"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409098" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409098">(Jan 18 2019 at 23:46)</a>:</h4>
<p>I haven't had time yet</p>



<a name="156409107"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409107" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409107">(Jan 18 2019 at 23:46)</a>:</h4>
<p>If you have time, feel free to go at it</p>



<a name="156409115"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409115" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409115">(Jan 18 2019 at 23:46)</a>:</h4>
<p>but I have a several day latency on actually having time to do anything :)</p>



<a name="156409127"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156409127" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156409127">(Jan 18 2019 at 23:47)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span>  I know the feeling :P</p>



<a name="156410117"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156410117" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156410117">(Jan 19 2019 at 00:06)</a>:</h4>
<p>hehe, yeah, that's not uncommon I also find! I feel you're legitimately in a better position to make this fix, so let's touch base on the wg-traits meeting on Monday, and decide then (if you haven't started by then) :-)</p>



<a name="156637562"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156637562" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156637562">(Jan 22 2019 at 20:41)</a>:</h4>
<blockquote>
<p>now that we're comfortable that there exists <em>some way</em> to model this more formally</p>
</blockquote>
<p>I mean I always believed that, but that's not the same as sort of <em>doing</em> it and convincing ourselves we're not messing something up. I guess though I could be persuaded to go ahead and revert the check on the premise that it seems almost certainly correct, and we'll deal with any unsoundness as we ever do :P</p>



<a name="156739577"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156739577" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156739577">(Jan 24 2019 at 01:02)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> I see your PR for issue (1). Good stuff. I think that covers (3) too. Will you be tackling (2) afterwards, out of curiosity?</p>



<a name="156746409"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156746409" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156746409">(Jan 24 2019 at 03:47)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> yeah I was going to</p>



<a name="156746410"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156746410" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Taylor Cramer <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156746410">(Jan 24 2019 at 03:47)</a>:</h4>
<p>but I haven't had time yet</p>



<a name="156746760"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/156746760" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#156746760">(Jan 24 2019 at 03:57)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> Okay cool. :-)</p>



<a name="157043612"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/157043612" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#157043612">(Jan 28 2019 at 17:57)</a>:</h4>
<p><span class="user-mention" data-user-id="127859">@Taylor Cramer</span> <span class="user-mention" data-user-id="116009">@nikomatsakis</span> Does <span class="user-mention" data-user-id="116118">@Matthew Jasper</span>'s bug report and my suggestion make sense on <a href="https://github.com/rust-lang/rust/pull/57870" target="_blank" title="https://github.com/rust-lang/rust/pull/57870">https://github.com/rust-lang/rust/pull/57870</a> ?</p>



<a name="161530806"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161530806" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161530806">(Mar 23 2019 at 15:45)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> so, it turns out I might need to speak to you about this after all... if you have time. the fix isn't as obvious as I'd hoped!</p>



<a name="161672351"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672351" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672351">(Mar 25 2019 at 18:22)</a>:</h4>
<p>So, <span class="user-mention" data-user-id="124069">@Alexander Regueiro</span>, what I was imagining is that we need some sort of "bound"</p>



<a name="161672432"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672432" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672432">(Mar 25 2019 at 18:23)</a>:</h4>
<p>In other words, when you "hide" lifetimes with <code>dyn Trait</code>, you can only do it because we have a lifetime bound <code>'b</code> on <code>dyn Trait</code> (i.e., <code>dyn Trait + 'b</code>) and the hidden type must outlive <code>'b</code></p>



<a name="161672446"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672446" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672446">(Mar 25 2019 at 18:23)</a>:</h4>
<p>It sounds like you were roughly coming to the same conclusion in that PR</p>



<a name="161672451"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672451" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672451">(Mar 25 2019 at 18:23)</a>:</h4>
<p>yeah</p>



<a name="161672455"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672455" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672455">(Mar 25 2019 at 18:23)</a>:</h4>
<p>though didn't quite eget there</p>



<a name="161672457"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672457" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672457">(Mar 25 2019 at 18:23)</a>:</h4>
<p>which I agree with</p>



<a name="161672481"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672481" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672481">(Mar 25 2019 at 18:24)</a>:</h4>
<p>I'm not exactly sure what form this should take</p>



<a name="161672539"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672539" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672539">(Mar 25 2019 at 18:24)</a>:</h4>
<p>but basically we can't "ignore' lifetimes unless there is <em>some</em> named lifetime that <em>is</em> captured which they outlive</p>



<a name="161672540"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672540" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672540">(Mar 25 2019 at 18:24)</a>:</h4>
<p>did you see matthewjasper's tricky way to create unsound behaviour?</p>



<a name="161672543"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672543" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672543">(Mar 25 2019 at 18:24)</a>:</h4>
<p>(a new one)</p>



<a name="161672546"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672546" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672546">(Mar 25 2019 at 18:24)</a>:</h4>
<p>right</p>



<a name="161672551"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672551" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672551">(Mar 25 2019 at 18:24)</a>:</h4>
<p>that makes sense, I think....</p>



<a name="161672609"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672609" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672609">(Mar 25 2019 at 18:25)</a>:</h4>
<p>I'm reading what they wrote now</p>



<a name="161672617"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672617" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672617">(Mar 25 2019 at 18:25)</a>:</h4>
<p>well ok so the problem is</p>



<a name="161672620"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672620" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672620">(Mar 25 2019 at 18:25)</a>:</h4>
<p>yeah, this makes sense</p>



<a name="161672628"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672628" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672628">(Mar 25 2019 at 18:25)</a>:</h4>
<p>so basically we can only allow this hiding if <code>opaque_defn.has_required_region_bounds</code>?</p>



<a name="161672640"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672640" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672640">(Mar 25 2019 at 18:25)</a>:</h4>
<p>that condition being necessary but not sufficient</p>



<a name="161672653"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672653" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672653">(Mar 25 2019 at 18:25)</a>:</h4>
<p>I think if you combine it with the condition I currently have, that may be enough then?</p>



<a name="161672710"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672710" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672710">(Mar 25 2019 at 18:26)</a>:</h4>
<p>so, when I was talking earlier, I mentioned that the way I wanted to think about this was basically "as if" we introduced an existential type construct</p>



<a name="161672804"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672804" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672804">(Mar 25 2019 at 18:26)</a>:</h4>
<p>in what sense? RPIT is already "kind of" existential. :-)</p>



<a name="161672834"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672834" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672834">(Mar 25 2019 at 18:27)</a>:</h4>
<p>not really</p>



<a name="161672846"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672846" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672846">(Mar 25 2019 at 18:27)</a>:</h4>
<p>I mean not in the sense I mean</p>



<a name="161672859"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672859" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672859">(Mar 25 2019 at 18:27)</a>:</h4>
<p>i.e., the hidden type in <span class="user-mention" data-user-id="116118">@Matthew Jasper</span>'s example is <code>Rc&lt;RefCell&lt;&amp;'b T&gt;&gt;</code> -- but that doesn't work beacuse it names <code>'b</code></p>



<a name="161672877"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672877" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672877">(Mar 25 2019 at 18:27)</a>:</h4>
<p>the hidden type would have to be <code>exists&lt;'b&gt; Rc&lt;RefCell&lt;&amp;'b T&gt;&gt;</code></p>



<a name="161672885"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672885" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672885">(Mar 25 2019 at 18:27)</a>:</h4>
<p>er</p>



<a name="161672896"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672896" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672896">(Mar 25 2019 at 18:27)</a>:</h4>
<p><code>exists&lt;'b: 'a&gt;  Rc&lt;RefCell&lt;&amp;'b T&gt;&gt;</code></p>



<a name="161672946"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672946" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672946">(Mar 25 2019 at 18:28)</a>:</h4>
<p>and the key point here is that this would not implement <code>Swap</code></p>



<a name="161672972"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672972" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672972">(Mar 25 2019 at 18:28)</a>:</h4>
<p>because <code>Swap</code> is implemented for <code>Rc&lt;RefCell&lt;&amp;'b T&gt;&gt;</code>, not <code>exists&lt;...&gt; ...</code></p>



<a name="161672986"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672986" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672986">(Mar 25 2019 at 18:28)</a>:</h4>
<p>anyway, this all feels tricky to me</p>



<a name="161672995"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161672995" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161672995">(Mar 25 2019 at 18:28)</a>:</h4>
<p>which is why I've been discouraging us from pushing too hard :)</p>



<a name="161673004"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673004" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673004">(Mar 25 2019 at 18:28)</a>:</h4>
<p>(though <span class="user-mention" data-user-id="116118">@Matthew Jasper</span>'s example is a very good one)</p>



<a name="161673062"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673062" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673062">(Mar 25 2019 at 18:29)</a>:</h4>
<p>and basically highlights where using a "real" existential type would start to differ from just ignoring stuff</p>



<a name="161673104"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673104" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673104">(Mar 25 2019 at 18:29)</a>:</h4>
<p>that said, there is a <em>different but related</em> area that might be worth pushing on</p>



<a name="161673118"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673118" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673118">(Mar 25 2019 at 18:29)</a>:</h4>
<p>that was blocking some of the async-await stuff</p>



<a name="161673186"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673186" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673186">(Mar 25 2019 at 18:30)</a>:</h4>
<p>yeah...</p>



<a name="161673190"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673190" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673190">(Mar 25 2019 at 18:30)</a>:</h4>
<p>hmm</p>



<a name="161673246"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673246" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673246">(Mar 25 2019 at 18:30)</a>:</h4>
<p>I spent a while <a href="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/Lifetime.20Fixes/near/161160286" title="#narrow/stream/187312-t-compiler.2Fwg-async-await/topic/Lifetime.20Fixes/near/161160286">outlining the problem/possible solutions</a> to <span class="user-mention" data-user-id="127859">@Taylor Cramer</span> over in <a class="stream" data-stream-id="187312" href="/#narrow/stream/187312-t-compiler.2Fwg-async-await">#t-compiler/wg-async-await</a></p>



<a name="161673251"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673251" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673251">(Mar 25 2019 at 18:30)</a>:</h4>
<p>do you have an example of where adding <code>+ 'b</code> to the bounds isn't good enough?</p>



<a name="161673253"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673253" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673253">(Mar 25 2019 at 18:30)</a>:</h4>
<p>okay</p>



<a name="161673256"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673256" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673256">(Mar 25 2019 at 18:30)</a>:</h4>
<p>I'll take a look</p>



<a name="161673262"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673262" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673262">(Mar 25 2019 at 18:30)</a>:</h4>
<blockquote>
<p>do you have an example of where adding <code>+ 'b</code> to the bounds isn't good enough?</p>
</blockquote>
<p>well that is good enough</p>



<a name="161673270"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673270" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673270">(Mar 25 2019 at 18:31)</a>:</h4>
<p>but that changes the whole problem</p>



<a name="161673293"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673293" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673293">(Mar 25 2019 at 18:31)</a>:</h4>
<p>that is, the problem is to find a way where we can have a type that includes lifetimes</p>



<a name="161673307"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673307" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673307">(Mar 25 2019 at 18:31)</a>:</h4>
<p>which are NOT part of the trait bounds</p>



<a name="161673312"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673312" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673312">(Mar 25 2019 at 18:31)</a>:</h4>
<p>i.e., which don't appear in the capture list</p>



<a name="161673341"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673341" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673341">(Mar 25 2019 at 18:31)</a>:</h4>
<p>and I think the answer is that, as <span class="user-mention" data-user-id="116118">@Matthew Jasper</span>'s example shows, we can't really do that very easily</p>



<a name="161673347"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673347" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673347">(Mar 25 2019 at 18:31)</a>:</h4>
<p>oh yes, duh</p>



<a name="161673351"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673351" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673351">(Mar 25 2019 at 18:31)</a>:</h4>
<p>hmm</p>



<a name="161673708"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673708" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673708">(Mar 25 2019 at 18:35)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> I'll take a look at that one in a bit, but for this issue, how would go around creating an existential type, binding by lifetime?</p>



<a name="161673718"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161673718" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161673718">(Mar 25 2019 at 18:35)</a>:</h4>
<p>in terms of implementation</p>



<a name="161674002"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674002" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674002">(Mar 25 2019 at 18:38)</a>:</h4>
<p>I mean, we have <code>for&lt;'a: 'b&gt;</code> already today as HRLB</p>



<a name="161674672"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674672" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674672">(Mar 25 2019 at 18:44)</a>:</h4>
<p><span class="user-mention" data-user-id="124069">@Alexander Regueiro</span> well, I don't quite know, to be totally honest =)</p>



<a name="161674745"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674745" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674745">(Mar 25 2019 at 18:44)</a>:</h4>
<p>heh, yeah, it's tricky...</p>



<a name="161674775"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674775" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674775">(Mar 25 2019 at 18:45)</a>:</h4>
<p>we'd have to figure out the rules for the type, which probably isn't <em>too</em> hard, but also define whre the "open and close" operations occur</p>



<a name="161674815"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674815" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674815">(Mar 25 2019 at 18:45)</a>:</h4>
<p>those would presumably be connected to returning a value from a fn w/ an RPIT</p>



<a name="161674846"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674846" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674846">(Mar 25 2019 at 18:45)</a>:</h4>
<p>open &amp; close?</p>



<a name="161674927"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674927" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674927">(Mar 25 2019 at 18:46)</a>:</h4>
<p>'close' refers to 'hiding' the existential lifetime</p>



<a name="161674930"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674930" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674930">(Mar 25 2019 at 18:46)</a>:</h4>
<p>right</p>



<a name="161674935"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674935" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> nikomatsakis <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674935">(Mar 25 2019 at 18:46)</a>:</h4>
<p>i.e., converting from <code>Foo&lt;'b&gt;</code> to <code>exists&lt;'b&gt; Foo&lt;'b&gt;</code></p>



<a name="161674982"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674982" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674982">(Mar 25 2019 at 18:46)</a>:</h4>
<p>that seems the more obvious (?) one: that could be done where I'm doing my checks now for hidden lifetimes</p>



<a name="161674987"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161674987" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161674987">(Mar 25 2019 at 18:47)</a>:</h4>
<p>in <code>constrain_type</code></p>



<a name="161675008"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161675008" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161675008">(Mar 25 2019 at 18:47)</a>:</h4>
<p>or whatever it's called</p>



<a name="161675018"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161675018" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161675018">(Mar 25 2019 at 18:47)</a>:</h4>
<p>opening... I'm not so sure!</p>



<a name="161675685"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161675685" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161675685">(Mar 25 2019 at 18:53)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> I can try to throw something together if you give me a few tips about how/where to do the opening :-)</p>



<a name="161675689"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161675689" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161675689">(Mar 25 2019 at 18:53)</a>:</h4>
<p>just experiment</p>



<a name="161778734"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161778734" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161778734">(Mar 26 2019 at 16:27)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span> so, I'm willing to pursue this, but I feel I'd need mentoring from someone who really understands the semantics and implementation... this could be informal, or in the form of an eRFC...</p>



<a name="161855836"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161855836" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161855836">(Mar 27 2019 at 12:54)</a>:</h4>
<p>I think the immediate next step here should be to add <span class="user-mention" data-user-id="116118">@Matthew Jasper</span>'s tests on both PRs as compile-fail tests to ensure that accidents don't occur.</p>



<a name="161855996"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/161855996" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> centril <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#161855996">(Mar 27 2019 at 12:56)</a>:</h4>
<p><span class="user-mention" data-user-id="116009">@nikomatsakis</span>  The notion of <code>exists&lt;'x: 'y&gt;</code> is appealing; It was discussed in <a href="https://medium.com/@GolDDranks/things-rust-doesnt-let-you-do-draft-f596a3c740a5" target="_blank" title="https://medium.com/@GolDDranks/things-rust-doesnt-let-you-do-draft-f596a3c740a5">https://medium.com/@GolDDranks/things-rust-doesnt-let-you-do-draft-f596a3c740a5</a> as a means of having "dependent lifetimes" which I found intriguing... Definitely worth exploring but will need deeper thinking + buy-in from the language team.</p>



<a name="162434630"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/162434630" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#162434630">(Apr 03 2019 at 14:29)</a>:</h4>
<p>hey <span class="user-mention" data-user-id="116009">@nikomatsakis</span>. got a bit of free time coming up to discuss RPIT existential lifetime issues more?</p>



<a name="162446418"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/162446418" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> tmandry <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#162446418">(Apr 03 2019 at 16:51)</a>:</h4>
<p>I think niko is on vacation this week <span class="user-mention" data-user-id="124069">@Alexander Regueiro</span></p>



<a name="162447624"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/144729-wg-traits/topic/RPIT%20Lifetime%20issues/near/162447624" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Alexander Regueiro <a href="https://rust-lang.github.io/zulip_archive/stream/144729-wg-traits/topic/RPIT.20Lifetime.20issues.html#162447624">(Apr 03 2019 at 17:04)</a>:</h4>
<p><span class="user-mention" data-user-id="116883">@tmandry</span> okay thanks</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>